FROM alpine
LABEL AUTHOR="ClegeA <amlhbmcxMjM1NzRAMTYzLmNvbQ==>"
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apk/repositories \
    && set -ex && apk update && apk upgrade \
    && apk add --update --no-cache curl tzdata python3 py3-pip git moreutils \
    && pip install --upgrade pip \
    && ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
    && echo "Asia/Shanghai" > /etc/timezone \
    && mkdir /jdc \
    && mkdir /jdc/data \
    && mkdir /jdc/data/config \
    && mkdir /jdc/data/logs \
    && cd /jdc \
    && git clone https://gitee.com/jiang123574/jdc.git \
    && pip install -r /jdc/jdc/requirements.txt \
    && crontab /jdc/jdc/mycrontab.sh \
CMD ["crond"]